﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

    <!--==============================================Button配色======================================================-->
    <!--通用按钮-->
    <SolidColorBrush x:Key="RedioButton_BgColor">#FFF1F1F1</SolidColorBrush>
    <SolidColorBrush x:Key="RedioButton_MouseOver_FgColor">#FFF88C0D</SolidColorBrush>
    <SolidColorBrush x:Key="RedioButton_MouseOver_BorderColor">#FFF88C0D</SolidColorBrush>
    <SolidColorBrush x:Key="RedioButton_Pressed_FgColor">#FFDE7C09</SolidColorBrush>
    <SolidColorBrush x:Key="RedioButton_Pressed_BorderColor">#FFDE7C09</SolidColorBrush>

    <!--Button-->
    <Style x:Key="IconRadioBtnStyle" TargetType="{x:Type RadioButton}">
        <Setter Property="FontSize" Value="15"/>
        <Setter Property="BorderThickness" Value="0"/>
        <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
        <Setter Property="Foreground" Value="{DynamicResource FgColor}"/>
        <Setter Property="BorderBrush" Value="{DynamicResource BorderColor}"/>
        <Setter Property="Background" Value="{x:Null}"/>
        <Setter Property="HorizontalContentAlignment" Value="Center"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type RadioButton}">
                    <Border x:Name="border" CornerRadius="0" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}">
                        <Grid x:Name="grid" Background="#009F1515">
                            <ContentPresenter x:Name="contentPresenter" 
                                              HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                              Margin="{TemplateBinding Padding}"
                                              RecognizesAccessKey="True" 
                                              SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" 
                                              VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
                            </ContentPresenter>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Style.Triggers>
            <Trigger Property="IsEnabled" Value="false">
                <Setter Property="Foreground" Value="{DynamicResource EnabledColor}"/>
                <Setter Property="BorderBrush" Value="{DynamicResource EnabledColor}"/>
            </Trigger>
            <Trigger Property="IsChecked" Value="True">
                <Setter Property="Foreground" Value="{DynamicResource EnabledColor}"/>
                <Setter Property="BorderThickness" Value="0"/>
            </Trigger>
            <Trigger Property="IsMouseOver"  Value="True">
                <Setter Property="Foreground" Value="{DynamicResource Button_MouseOver_FgColor}"/>
                <Setter Property="BorderBrush" Value="{DynamicResource Button_MouseOver_BorderColor}"/>
            </Trigger>
            <Trigger Property="IsPressed" Value="True">
                <Setter Property="Foreground" Value="{StaticResource Button_Pressed_FgColor}"/>
                <Setter Property="BorderBrush" Value="{StaticResource Button_Pressed_BorderColor}"/>
            </Trigger>
        </Style.Triggers>
    </Style>
    
</ResourceDictionary>